---
apiVersion: v1
kind: Service
metadata:
  name: nginx-nodeport
  namespace: default
spec:
  type: NodePort
  ports:
    - port: 80
      name: http
      protocol: TCP
      targetPort: http
      nodePort: 31080
  selector:
    k8s-app: nginx